<?php
Zend_Session::start();
class Default_Bootstrap extends Zend_Application_Module_Bootstrap
{
	
	protected function _initAppAutoload()
	{	//'App'

	    $autoloader = new Zend_Application_Module_Autoloader(array(
	        'namespace' => 'Default',
	        'basePath' => dirname(__FILE__).DS.'modules'.DS.'default',
	    ));

	    $router = Zend_Controller_Front::getInstance()->getRouter(); // returns a rewrite router by default
	    $router->addRoute(
	                'categories',
	    			new Zend_Controller_Router_Route('categories/:id/:title',
	    				array(	'controller' => 'categories','action' => 'list')
	    			)
	    );
	    
	    $router = Zend_Controller_Front::getInstance()->getRouter();
	    $router->addRoute(
	    	            'products',
	    				new Zend_Controller_Router_Route('products/:id/:title/:catid',
	    					array(	'controller' => 'products','action' => 'details')
	    				)
	    );
	    return $autoloader;
	}
        

}
